#ifndef __STM32_H
#define __STM32_H

#include "zf_common_headfile.h"

//
typedef struct
{
  float q0;
  float q1;
  float q2;
  float q3;
}Q;

typedef struct
{
    float accX;
    float accY;
    float accZ;
    float gyroX;
    float gyroY;
    float gyroZ;
}_st_Mpu;

typedef struct
{
    float roll;
    float pitch;
    float yaw;
}_st_AngE;
typedef struct {
    float Xdata;
    float Ydata;
    float Zdata;
} gyro_param_t;

void GetAngle(const _st_Mpu *pMpu,_st_AngE *pAngE, float dt);
float Q_rsqrt(float number);
void icm20602_get_init(void);
void gyro_ZsetInit(void);
void gyroOffset_init(void);
void ICM_getValues(void);

extern _st_AngE  icm_angle;

#endif
